#ifndef SCENEMANAGER_HPP
# define SCENEMANAGER_HPP

# include <QDomDocument>
# include <QDomElement>
# include <QString>
# include "Scene.hpp"

class SceneManager
{
public:
    SceneManager();

    Scene*  load(std::string const& fileName);
    void    save(const std::string &fileName, Scene& scene);

private:
    void    writeToFile(QDomDocument& document, std::string const& fileName);
    void    addToDom(QDomDocument& document, QDomElement& element, QString const& name, QString const& value);
    void    addToDom(QDomDocument& document, QDomElement& element, QString const& name, int value);
    void    addToDom(QDomDocument& document, QDomElement& element, QString const& name, unsigned int value);
    void    addToDom(QDomDocument& document, QDomElement& element, QString const& name, float value);
};

#endif // SCENEMANAGER_HPP
